using System;
using digit.Core;
using System.Data;

namespace SMS.MediaManager
{
	public class MidiInfo
	{
		#region CONSTRUCTORS
		public MidiInfo()
		{
		
			this.m_midiID = Util.NULL_LONG;
			this.m_midiName = Util.NULL_STRING;
			this.m_midiName1 = Util.NULL_STRING;
			this.m_midiName2 = Util.NULL_STRING;
			this.m_categoryID = Util.NULL_INT;
			this.m_midiURL = Util.NULL_STRING;
			this.m_midiData = null;
			this.m_midiLength = Util.NULL_INT;
			this.m_midiMono = Util.NULL_STRING;
			this.m_author = Util.NULL_STRING;
			this.m_singer = Util.NULL_STRING;
			this.m_mime = Util.NULL_STRING;
			this.m_location = Util.NULL_STRING;
			this.m_sMSCount = Util.NULL_LONG;
			this.m_createdBy = Util.NULL_STRING;
			this.m_createdDate = Util.NULL_DATETIME;
            this.m_status = Util.NULL_BYTE;
		}
		public MidiInfo( long midiID,  string midiName,  string midiName1,  string midiName2,  int categoryID,  string midiURL,  byte[] midiData,  int midiLength,  string midiMono,  string author,  string singer,  string mime,  string location,  long sMSCount,  string createdBy,  DateTime createdDate,  byte status)
		{
		
			this.m_midiID = midiID;
			this.m_midiName = midiName;
			this.m_midiName1 = midiName1;
			this.m_midiName2 = midiName2;
			this.m_categoryID = categoryID;
			this.m_midiURL = midiURL;
			this.m_midiData = midiData;
			this.m_midiLength = midiLength;
			this.m_midiMono = midiMono;
			this.m_author = author;
			this.m_singer = singer;
			this.m_mime = mime;
			this.m_location = location;
			this.m_sMSCount = sMSCount;
			this.m_createdBy = createdBy;
			this.m_createdDate = createdDate;
			this.m_status = status;
		}
		public MidiInfo( DataRow dRow)
		{
		
			this.m_midiID = (long) Util.ReplaceDBNullTo(dRow["midiID"], Util.NULL_LONG);
			this.m_midiName = Util.ReplaceDBNullTo(dRow["midiName"], Util.NULL_STRING).ToString();
			this.m_midiName1 = Util.ReplaceDBNullTo(dRow["midiName1"], Util.NULL_STRING).ToString();
			this.m_midiName2 = Util.ReplaceDBNullTo(dRow["midiName2"], Util.NULL_STRING).ToString();
			this.m_categoryID = (int) Util.ReplaceDBNullTo(dRow["categoryID"], Util.NULL_INT);
			this.m_midiURL = Util.ReplaceDBNullTo(dRow["midiURL"], Util.NULL_STRING).ToString();
			this.m_midiData = (byte[]) Util.ReplaceDBNullTo(dRow["midiData"], null);
			this.m_midiLength = (int) Util.ReplaceDBNullTo(dRow["midiLength"], Util.NULL_INT);
			this.m_midiMono = Util.ReplaceDBNullTo(dRow["midiMono"], Util.NULL_STRING).ToString();
			this.m_author = Util.ReplaceDBNullTo(dRow["author"], Util.NULL_STRING).ToString();
			this.m_singer = Util.ReplaceDBNullTo(dRow["singer"], Util.NULL_STRING).ToString();
			this.m_mime = Util.ReplaceDBNullTo(dRow["mime"], Util.NULL_STRING).ToString();
			this.m_location = Util.ReplaceDBNullTo(dRow["location"], Util.NULL_STRING).ToString();
			this.m_sMSCount = (long) Util.ReplaceDBNullTo(dRow["sMSCount"], Util.NULL_LONG);
			this.m_createdBy = Util.ReplaceDBNullTo(dRow["createdBy"], Util.NULL_STRING).ToString();
			this.m_createdDate = (DateTime) Util.ReplaceDBNullTo(dRow["createdDate"], Util.NULL_DATETIME);
			this.m_status = (byte) Util.ReplaceDBNullTo(dRow["status"], 2);
		}
		#endregion
		
		#region ATTRIBUTES
		private long m_midiID;
		private string m_midiName;
		private string m_midiName1;
		private string m_midiName2;
		private int m_categoryID;
		private string m_midiURL;
		private byte[] m_midiData;
		private int m_midiLength;
		private string m_midiMono;
		private string m_author;
		private string m_singer;
		private string m_mime;
		private string m_location;
		private long m_sMSCount;
		private string m_createdBy;
		private DateTime m_createdDate;
		private byte m_status;
		#endregion
		
		#region PROPERTIES
		public long MidiID
		{
			get
			{
				return this.m_midiID;
			}
			set
			{
				this.m_midiID = value;
			}
		}
		
		public string MidiName
		{
			get
			{
				return this.m_midiName;
			}
			set
			{
				this.m_midiName = value;
			}
		}
		
		public string MidiName1
		{
			get
			{
				return this.m_midiName1;
			}
			set
			{
				this.m_midiName1 = value;
			}
		}
		
		public string MidiName2
		{
			get
			{
				return this.m_midiName2;
			}
			set
			{
				this.m_midiName2 = value;
			}
		}
		
		public int CategoryID
		{
			get
			{
				return this.m_categoryID;
			}
			set
			{
				this.m_categoryID = value;
			}
		}
		
		public string MidiURL
		{
			get
			{
				return this.m_midiURL;
			}
			set
			{
				this.m_midiURL = value;
			}
		}
		
		public byte[] MidiData
		{
			get
			{
				return this.m_midiData;
			}
			set
			{
				this.m_midiData = value;
			}
		}
		
		public int MidiLength
		{
			get
			{
				return this.m_midiLength;
			}
			set
			{
				this.m_midiLength = value;
			}
		}
		
		public string MidiMono
		{
			get
			{
				return this.m_midiMono;
			}
			set
			{
				this.m_midiMono = value;
			}
		}
		
		public string Author
		{
			get
			{
				return this.m_author;
			}
			set
			{
				this.m_author = value;
			}
		}
		
		public string Singer
		{
			get
			{
				return this.m_singer;
			}
			set
			{
				this.m_singer = value;
			}
		}
		
		public string Mime
		{
			get
			{
				return this.m_mime;
			}
			set
			{
				this.m_mime = value;
			}
		}
		
		public string Location
		{
			get
			{
				return this.m_location;
			}
			set
			{
				this.m_location = value;
			}
		}
		
		public long SMSCount
		{
			get
			{
				return this.m_sMSCount;
			}
			set
			{
				this.m_sMSCount = value;
			}
		}
		
		public string CreatedBy
		{
			get
			{
				return this.m_createdBy;
			}
			set
			{
				this.m_createdBy = value;
			}
		}
		
		public DateTime CreatedDate
		{
			get
			{
				return this.m_createdDate;
			}
			set
			{
				this.m_createdDate = value;
			}
		}
		
		public byte Status
		{
			get
			{
				return this.m_status;
			}
			set
			{
				this.m_status = value;
			}
		}
		
		#endregion
		
	}
}